#pragma once

#include "FreeImage.h"
#include "Batch.h"

class CPageProDoc : public CDocument
{
protected: // create from serialization only
	CPageProDoc();
	DECLARE_DYNCREATE(CPageProDoc)

// Attributes
public:
	CBatch m_batch;
	FIBITMAP* m_dib;

// Operations
public:

// Overrides
public:
	virtual BOOL OnNewDocument();
	virtual void Serialize(CArchive& ar);
#ifdef SHARED_HANDLERS
	virtual void InitializeSearchContent();
	virtual void OnDrawThumbnail(CDC& dc, LPRECT lprcBounds);
#endif // SHARED_HANDLERS

// Implementation
public:
	virtual ~CPageProDoc();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:
	BOOL OpenBatch(BOOL loadThumbnailCtrl = FALSE);

// Generated message map functions
protected:
	DECLARE_MESSAGE_MAP()
	
public:
	afx_msg void OnFileOpen();
	afx_msg void OnFileClose();
#ifdef SHARED_HANDLERS
	// Helper function that sets search content for a Search Handler
	void SetSearchContent(const CString& value);
#endif // SHARED_HANDLERS
};
